This invention relates to programmable controllers for industrial robots, and more particularly to programmable controllers for factory cells including one or more robots for assembling, for example, the parts of automotive vehicles.
FIG. 1 shows schematically a factory cell consisting of an industrial robot (commercially available from Mitsubishi Electric Corporation under a trade name MELFA-PICKARM) and the robot controller, provided with a conventional programmable controller, generally referred to as a sequencer (commercially availabe from Mitsubishi Electric Corporation under the trade name MELSEC). The system shown in FIG. 1 comprises: a factory cell 3 including a robot (at the bottom of the figure), a robot controller 2 (top right), and a programmable controller 1 (top left).
The programmable controller or sequencer 1 is provided with a program input device 19 via which a program (written, for example, in a ladder language, as described below) is inputted for sequencing the operations of the whole factory cell. The box within the block 19 shows an example of the display screen of the console of the input device 19. Further, a memory circuit 12 stores the program inputted via the input device 19. A processing circuit 16 interprets the program stored in the memory 12. Further, an input/output circuit 17 executes input/output operations on the basis of the interpretations of the program effected by the processing circuit 16, wherein a communication means 15 performs communications with the robot controller 2. The programmable controller (sequencer) comprises the circuits and means 12, 16, 15, and 17 as described above.
On the other hand, the robot controller 2 is provided with a program input device 29 via which a program (written, for example, in a robot language as described below) describing the operations of the robot in a sequential order is inputted. The box within the block 29 shows an example of the inputted program displayed on the screen of the input device 29. A program memory circuit 28 stores the program inputted via the input device 29. A processing circuit 27 interprets the program stored in the memory 28. Further, a driving circuit 23 drives the robot on the basis of the interpretations of the program effected by the processing circuit 27, wherein a communication means 21 communicates with the programmable controller 1. The robot controller comprises circuits and means 28, 27, 21, and 23 as described above.
The factory cell 3, on the other hand, comprises a robot arm 31, a fixing device 32 for fixing the work (object), a sensor 33 for detecting the object, a conveyer 34, and operation indicator lamps 35.
In the case of a typical conventional device, communication between the factory cell 3 (provided with the robot controller 2), and the programmable controller 1 was realized by individually connecting the general purpose input/output terminals of the robot and the controller. In the case of the device of FIG. 1, such complicated wiring can largely be dispensed with. Namely, a single communication cable or bus (referred to as a sequencer link) connects the communication means 15 of the programmable controller 1 to communication means 21 of the robot controller 2 such that the system input/output and the general purpose input/output signals of the robot controller 2 are allotted and coupled to the exclusive input/output terminals of the programmable controller 1 according to a correspondence table.
A typical sequence of operations of the robot is shown in FIG. 6. First, at step 41, the reception of the object (work) is confirmed. Next, at step 42, the object is fixed, and at step 43, the robot is started. Further, at step 44, the kind of object is discriminated, and the operation of the robot is selected accordingly. At step 45, the completion of the operation of the robot is waited for and confirmed, and finally, at step 46, the object is released.
The series of operations of the factory cell 3 must be described by the ladder language as shown in FIG. 2 with respect to the programmable controller 1, and, further, by a robot language as shown in FIG. 3 with respect to the robot controller 2.
FIG. 2 shows an example of the program of the programmable controller 1, where the numerals at the left are the line numbers, and the words between the lines are the comments on the program.
Lines 1 through 3 of FIG. 2 correspond to the steps 41 and 42 in FIG. 6, where the reception of the object is confirmed and the object is fixed. The relay Y1 starts the cylinder of the fixing device 32 for fixing the object. Further, lines 4 through 22 correspond to step 43 of FIG. 6 where the robot is started. The correspondence or allotment between the ports (or contacts) of the communication means of the programmable controller 1 and those of the robot (including the robot controller 2) are effected in accordance with a correspondence table. (For example, the output port or contact Y1F5 of the programmable controller 1 which is set at line 7 of FIG. 2 corresponds to the automatic mode selection input of the robot controller 2.) Further, at lines 23 through 26 corresponding to step 44 of FIG. 6, the kind of the object is discriminated on basis of the states of the input ports or contacts X1 and X2 of the programmable controller 1, and the result of the discrimination is communicated to the robot controller 2 via the output port or contact Y1E0 of the programmable controller 1 (corresponding to the input port IN 37 of the robot controller 2 in accordance with the correspondence table) and via the output port or contact Y1E1 of the programmable controller 1 (corresponding to the input port IN 38 of the robot controller 2 in accordance with the correspondance table). The establishment of the communication is confirmed via the input port X1CO of the controller 1 (corresponding to the output port OUT 37 of the robot controller 2). Further, at lines 27 through 28, the completion of the operation of the robot is waited and confirmed (step 45 in FIG. 6), and at line 29, the object is released (step 46 in FIG. 6).
FIG. 3 shows the program inputted to the robot controller 2, which corresponds to the above ladder language program of the programmable controller 1. The program describes the sequential order of operations in steps 51 through 63.
First, at step 51 in FIG. 3, the output port or contact OUT 37 of the robot controller 2 for confirming the establishment of the communication is initialized to 0. At the subsequent steps 52 and 53, a communication with the programmable controller 1 is effected so as to select the kind of operation of the robot in accordance with the kind of the object (work). The input ports or contacts IN 37 and IN 38 of the robot controller 2 correspond, and hence are coupled, to the output ports Y1E0 and Y1E1 of the programmable controller 1, respectively. If the input port IN 37 is on (IN 37=1) at step 52, then the series of operations at steps 54 through 58 are selected, and the execution proceeds to step 54, where the output port or contact OUT 37 (corresponding to the input port X1C0) of the programmable controller 1) is turned on (OUT 37=1) so as to notify the establishment of the communication to the programmable controller 1. Thereafter, at the subsequent steps 55 through 57, the robot arm operations are effected as indicated thereat, to end the routine at step 58. When the END command is effected at step 58, a signal is transmitted to the input port X1D8 of the programmable controller 1, to notify the programmable controller of the completion of the operation of the robot. When, on the other hand, the input port IN 38 is on (IN 38=1) at step 53, the execution proceeds to step 59, and operations similar to the above are effected at the subsequent steps 60 through 63.
The above device of FIG. 1, however, has the following disadvantages.
First, since the programming is divided into two parts, the programming of the operations of the robot as a whole is difficult. The programming of the programmable controller is done in a ladder language capable of describing the parallel operations, while that of the robot controller is done in the robot language describing sequential operations. The programming as a whole must be done in two different languages and hence is complicated and time-consuming. The operations of the robot are not explicit upon the face of the program of the programmable controller, which controls the whole operations of the factory cell. On the other hand, it is difficult to have a clear view of the operations of the whole factory cell from the program of the robot controller. Unless the correspondence table of the input/output ports or contacts of the controller and the robot controller are referred to, the correspondence or connections of these ports or contacts cannot be known. Thus, the efficiency of writing or maintaining the program is low.
A further disadvantage is that the execution of the program is time-consuming since the frequent reciprocal communications between the two controllers 1 and 2 take time. Namely, during the execution of the program, the synchronization and the communication between the programmable and the robot controllers require frequent operations of the I/O ports or contacts of the two controllers based on the correspondence table.